package com.woniuxy.mapper;

import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;

import com.woniuxy.entity.CategoryOne;

@Mapper
public interface CategoryTwoMapper {
	
	@Select("select * from category_two")
	public CategoryOne findCategoryTwo();
	
	 @Insert("insert into category_one values(default,#{co_id},#{type})")
	public int addCategoryTwo(String type,int co_id);
	 
	 @Delete("delete from category_one where ct_id=#{ct_id}")
	 public int delCategoryTwo(int ct_id);
	 
	 @Update("update category_one set co_id=#{co_id} type=#{type} where ct_id=#{ct_id}")
	 public int updateCategoryOne(String type,int co_id,int ct_id);
	 

}
